package com.mervin.bean;

import com.mervin.annotation.LineFieldAnnotation;
import com.mervin.annotation.LineParseAnnotation;
import com.mervin.enums.LineParseTypeEnum;

import java.math.BigDecimal;

/***************************************
 * @author: mervin
 * @Date: 2020-05-04 13:25
 * @Description:
 ***************************************/
@LineParseAnnotation(parseType = LineParseTypeEnum.SEPARATE, length = 5)
public class Student extends Person {

    @LineFieldAnnotation(index = 3)
    private String grade;

    @LineFieldAnnotation(index = 2)
    private BigDecimal score;

    public String getGrade() {
        return grade;
    }

    public void setGrade(String grade) {
        this.grade = grade;
    }

    public BigDecimal getScore() {
        return score;
    }

    public void setScore(BigDecimal score) {
        this.score = score;
    }

    @Override
    public String toString() {
        return "Student{" +
                "grade='" + grade + '\'' +
                ", score=" + score +
                ", id=" + id +
                ", name='" + name + '\'' +
                ", age=" + age +
                '}';
    }
}
